package sevensoft.结构型模式.组合模式;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.Getter;
import lombok.NoArgsConstructor;

@Getter
public abstract class FileComponent {
    protected String name;

    protected int level;

    public FileComponent(String name, int level) {
        this.name = name;
        this.level = level;
    }


    public abstract FileComponent add(FileComponent fileComponent);

    public abstract FileComponent remove(FileComponent fileComponent);

    public abstract FileComponent getChild(int level);

    public abstract void out();


}
